package com.pignest.framework.json;

public class JsonBoolean extends JsonValue {

	private final boolean value;

	public JsonBoolean(boolean value) {
		this.value = value;
	}

	public JsonBoolean(String text) {
		value = Boolean.parseBoolean(text);
	}

	@Override
	public boolean getBoolean() {
		return value;
	}

	@Override
	public String toExternalRepresentation() {
		return Boolean.toString(value);
	}
}
